//package com.douqu.game.main.platform;
//
//import com.bean.core.util.FormatUtils;
//import com.douqu.game.core.database.model.UserModel;
//import com.douqu.game.core.protobuf.SGCommonProto;
//import com.douqu.game.core.util.LogUtils;
//import com.douqu.game.core.util.CoreUtils;
//import com.douqu.game.main.service.PlayerService;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.stereotype.Component;
//
///**
// * Author : Bean
// * 2017-05-20 17:07
// */
//@Component
//public class PhoneImpl implements PlatformSDK {
//
//
//    @Autowired
//    private PlayerService playerService;
//
//    @Override
//    public UserModel login(String phone, String password)
//    {
//        if(!FormatUtils.checkPhoneFormat(phone))
//        {
//            LogUtils.debug("手机号码格式错误:" + phone);
//            return new UserModel();
//        }
//        String account = CoreUtils.createAccount(phone, SGCommonProto.E_CHANNEL_TYPE.CHANNEL_TYPE_PHONE);
//        UserModel player = playerService.getUserByAccount(account);
//        return player;
//    }
//
//
//}
